CREATE TABLE restricteduielements (
	nameorvalue VARCHAR(255) NOT NULL,
	roleid INT NOT NULL,
	PRIMARY KEY (nameorvalue, roleid)
);
GO

ALTER TABLE restricteduielements 
	ADD CONSTRAINT FK86718E26F22F129 
	FOREIGN KEY (roleid) 
	REFERENCES role;
GO

INSERT INTO restricteduielements(nameorvalue,roleid) values ('AASS Overdue',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('AASS Overdue',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('AASS Overdue',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('AASS Overdue',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('AASS Overdue',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Donor Award Ending',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Donor Award Ending',2);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Final Audit Past Due',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Final Audit Past Due',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Final Audit Past Due',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Final Audit Past Due',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Final Audit Past Due',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Financial Report Past Due',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Financial Report Past Due',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Financial Report Past Due',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Financial Report Past Due',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Financial Report Past Due',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Interim Audit Past Due',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Interim Audit Past Due',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Interim Audit Past Due',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Interim Audit Past Due',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Interim Audit Past Due',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Narrative Report Past Due',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Narrative Report Past Due',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Narrative Report Past Due',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Narrative Report Past Due',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Narrative Report Past Due',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Partner Grant Payment Request Activity',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Partner Grant Payment Request Activity',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Partner Grant Payment Request Activity',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Partner Grant Payment Request Activity',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Partner Grant Payment Request Activity',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Project Payment Request Activity',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Project Payment Request Activity',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Project Payment Request Activity',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Project Payment Request Activity',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('No Project Payment Request Activity',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant End Date Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant End Date Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant End Date Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant End Date Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant End Date Changed',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Start Date Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Start Date Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Start Date Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Start Date Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Start Date Changed',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Status Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Status Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Status Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Status Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Grant Status Changed',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Partner Grants Funds Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Partner Grants Funds Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Partner Grants Funds Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Partner Grants Funds Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Partner Grants Funds Changed',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project End Date Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project End Date Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project End Date Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project End Date Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project End Date Changed',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Management Funds Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Management Funds Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Management Funds Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Management Funds Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Management Funds Changed',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Start Date Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Start Date Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Start Date Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Start Date Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Start Date Changed',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Status Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Status Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Status Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Status Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Project Status Changed',6);

INSERT INTO restricteduielements(nameorvalue,roleid) values ('Payment Request Status Changed',1);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Payment Request Status Changed',2);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Payment Request Status Changed',3);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Payment Request Status Changed',4);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Payment Request Status Changed',5);
INSERT INTO restricteduielements(nameorvalue,roleid) values ('Payment Request Status Changed',6);

UPDATE changenotificationtype SET typename = 'Payment Request Status Changed' WHERE id = '2';

GO


SET IDENTITY_INSERT [dbo].[userpreference] ON
INSERT INTO [dbo].[userpreference] ([id], [aadateid], [aaid], [cndateid], [cnid], [pmasignid], [pmreagionid], [paymentasignid], [pgasignid], [pgreagionid], [aareagionid], [aaasignid], [cnreagionid], [cnasignid]) VALUES (N'331', N'1', N'8', null, null, null, null, null, null, null, null, null, null, null);
GO

SET IDENTITY_INSERT [dbo].[userpreference] OFF
GO

SET IDENTITY_INSERT[dbo].[userinfo]  ON
GO
INSERT INTO [dbo].[userinfo] ([id], [password], [loginname], [firstname], [middlename], [lastname], [email], [phone], [statuscode], [employeeid], [enddate], [startdate], [inactive], [requiredhours], [creationdate], [createdby], [lastupdated], [lastupdatedby], [fieldofficeid], [regionid], [usertypeid], [createdate], [preferenceid]) VALUES (N'225', N'2A97516C354B68848CDBD8F54A226A0A55B21ED138E207AD6C5CBB9C00AA5AEA', N'ashevis', N'Andrew', N'', N'Shevis', null, N'', N'Active', N'tio', null, null, null, null, null, N'211', N'2012-05-09 18:05:43.437', null, null, null, null, N'2012-04-05 15:07:10.117', N'331');
INSERT INTO [dbo].[userinfo] ([id], [password], [loginname], [firstname], [middlename], [lastname], [email], [phone], [statuscode], [employeeid], [enddate], [startdate], [inactive], [requiredhours], [creationdate], [createdby], [lastupdated], [lastupdatedby], [fieldofficeid], [regionid], [usertypeid], [createdate], [preferenceid]) VALUES (N'226', N'F70BA63512D5BF94F11E8BCF054A4B6E308F68F02D4EF0AA7B543B2799260A78', N'bnickerson', N'Brandon', N'', N'Nickerson', N'bnickerson@cipe.org', N'', N'Active', N'', null, null, null, null, null, N'211', N'2012-05-04 11:29:05.147', N'211', null, null, null, N'2012-05-04 11:29:02.727', null);
INSERT INTO [dbo].[userinfo] ([id], [password], [loginname], [firstname], [middlename], [lastname], [email], [phone], [statuscode], [employeeid], [enddate], [startdate], [inactive], [requiredhours], [creationdate], [createdby], [lastupdated], [lastupdatedby], [fieldofficeid], [regionid], [usertypeid], [createdate], [preferenceid]) VALUES (N'227', N'2A97516C354B68848CDBD8F54A226A0A55B21ED138E207AD6C5CBB9C00AA5AEA', N'shudak', N'Sara', N'', N'Hudak', N'shudak@cipe.org', N'', N'Active', N'', null, null, null, null, null, N'211', N'2012-05-04 11:36:00.997', N'211', null, null, null, N'2012-05-04 11:36:00.997', null);
INSERT INTO [dbo].[userinfo] ([id], [password], [loginname], [firstname], [middlename], [lastname], [email], [phone], [statuscode], [employeeid], [enddate], [startdate], [inactive], [requiredhours], [creationdate], [createdby], [lastupdated], [lastupdatedby], [fieldofficeid], [regionid], [usertypeid], [createdate], [preferenceid]) VALUES (N'228', N'2A97516C354B68848CDBD8F54A226A0A55B21ED138E207AD6C5CBB9C00AA5AEA', N'mchen', N'Michelle', N'', N'Chen', null, N'', N'Active', N'', null, null, null, null, null, N'211', N'2012-05-04 11:37:45.770', N'211', null, null, null, N'2012-05-04 11:37:45.770', null);
SET IDENTITY_INSERT[dbo].[userinfo]  OFF
GO

insert into userrole(userinfoid, roleid) values ((select id from userinfo where loginname = 'ashevis'), 1);
insert into userrole(userinfoid, roleid) values ((select id from userinfo where loginname = 'bnickerson'), 4);
insert into userrole(userinfoid, roleid) values ((select id from userinfo where loginname = 'shudak'), 4);
insert into userrole(userinfoid, roleid) values ((select id from userinfo where loginname = 'mchen'), 4);
GO